Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support use_enum_values in ConfigDict #2134

Merged
merged 2 commits into from
Nov 7, 2024
Merged

Support use_enum_values in ConfigDict #2134

merged 2 commits into from
Nov 7, 2024

Conversation

nbro10
Copy link
Contributor

@nbro10 nbro10 commented Oct 23, 2024

#466 (reply in thread)

Meanwhile, I am trying to override the ConfigDict.jinja2 template, but it doesn't work - it seems to be ignored

model_config = ConfigDict(
{%- for field_name, value in config.dict(exclude_unset=True).items() %}
    {{ field_name }}={{ value }},
{%- endfor %}
    use_enum_values=True
)

See #2136

Copy link

codecov bot commented Nov 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (d306553) to head (5907ab8).
Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #2134   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           38        38           
  Lines         4250      4251    +1     
  Branches       984       984           
=========================================
+ Hits          4250      4251    +1     
Flag Coverage Δ
unittests 99.67% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

codspeed-hq bot commented Nov 5, 2024

CodSpeed Performance Report

Merging #2134 will not alter performance

Comparing nbro10:main (5907ab8) with main (d306553)

Summary

✅ 30 untouched benchmarks

@koxudaxi koxudaxi merged commit e208c0a into koxudaxi:main Nov 7, 2024
76 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants